<template>
  <div class="home">
    <img alt="Vue logo" src="../assets/logo.png">
    <div v-for="item in mgs" :key=item.id>
      id:{{item.id}}
      email:{{item.email}}
      username:{{item.username}}
    </div>
  </div>
</template>

<script>
import axios from 'axios'
require('../mock/mock.js')

export default {
  name: 'Home',
  data(){
    return{
      mgs:[]
    }
  },
  components: {
    
  },
  created(){
    axios.get('/user/detail')
    .then(res=>{
        console.log(res);
        this.mgs=res.data
    })
    .catch(err=>{
      console.log(err)
    })
  },
  mounted(){
  }

}
</script>
